package com.lesso.zgs.sunflower.app.service.impl;

import com.baomidou.mybatisplus.plugins.Page;
import com.lesso.zgs.sunflower.domain.service.AttendanceRuleDomainService;
import com.lesso.zgs.sunflower.pojo.dto.AttendanceRuleDTO;
import com.lesso.zgs.sunflower.pojo.dto.AttendanceRuleQueryDTO;
import com.lesso.zgs.sunflower.pojo.vo.AttendanceRuleVO;
import com.lesso.zgs.sunflower.service.IAttendanceRuleService;
import org.apache.dubbo.config.annotation.DubboService;

/**
 * <p>
 * 考勤规则 服务实现类
 * </p>
 *
 * @author zgs
 * @since 2025-07-03
 */
@DubboService
public class AttendanceRuleServiceImpl implements IAttendanceRuleService {

    private final AttendanceRuleDomainService attendanceRuleDomainService;

    public AttendanceRuleServiceImpl(AttendanceRuleDomainService attendanceRuleDomainService) {
        this.attendanceRuleDomainService = attendanceRuleDomainService;
    }

    @Override
    public Integer save(AttendanceRuleDTO dto) {
        return attendanceRuleDomainService.save(dto);
    }

    @Override
    public AttendanceRuleDTO getById(Long id) {
        return attendanceRuleDomainService.getById(id);
    }

    @Override
    public Integer update(AttendanceRuleDTO dto) {
        return attendanceRuleDomainService.update(dto);
    }

    @Override
    public Integer delete(Long id) {
        return attendanceRuleDomainService.delete(id);
    }

    @Override
    public Page<AttendanceRuleVO> page(AttendanceRuleQueryDTO dto) {
        return attendanceRuleDomainService.page(dto);
    }
} 